package com.scs.application.modules.base.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.scs.application.core.entity.DataEntity;
import com.scs.application.modules.upgrade.db.annotation.EntityClassAnnotation;
import com.scs.application.modules.upgrade.db.annotation.EntityFieldAnnotation;
import com.scs.application.modules.upgrade.db.annotation.EntityIndexAnnotation;
import com.scs.application.modules.upgrade.db.enums.EntityFieldType;
import lombok.Data;
import lombok.experimental.Accessors;
/**
 * <p>
 * 院方科室
 * </p>
 */
@Data
@Accessors(chain = true)
@EntityClassAnnotation(remark = "院方科室表")
@TableName("base_dept")
@EntityIndexAnnotation(ux = {"hrp_code"})
public class Dept extends DataEntity {


    // id ,在父类中处理

    @EntityFieldAnnotation(
            text = "机构ID",
            type = EntityFieldType.LONG,
            length = "",
            not_null = true,
            default_value = "",
            comment = ""
    )
    private String officeId;

    @EntityFieldAnnotation(
            text = "编号",
            length = "30",
            not_null = true,
            default_value = "",
            comment = ""
    )
    private String officeSystemCode;

    @EntityFieldAnnotation(
            text = "科室名称",
            length = "50",
            not_null = true,
            default_value = "",
            comment = ""
    )
    private String name;
    private String namePy;

    @EntityFieldAnnotation(
            text = "是否是业务科室",
            length = "",
            not_null = true,
            default_value = "1",
            comment = ""
    )
    private Boolean flagBus;

    @EntityFieldAnnotation(
            text = "业务类型",
            length = "",
            not_null = true,
            default_value = "0",
            comment = "0：普通；1：手术室；2手术间；3：介入室；4：有二级库的科室；5：普通病区；"
    )
    private String busType;

    @EntityFieldAnnotation(
            text = "his编码",
            length = "30",
            not_null = false,
            default_value = "",
            comment = ""
    )
    private String hisCode;
    private String hisId;



    @EntityFieldAnnotation(
            text = "his名称",
            length = "100",
            not_null = false,
            default_value = "",
            comment = ""
    )
    private String hisName;

    @EntityFieldAnnotation(
            text = "hrp编码",
            length = "30",
            not_null = false,
            default_value = "",
            comment = ""
    )
    private String hrpCode;

    @EntityFieldAnnotation(
            text = "hrp名称",
            length = "100",
            not_null = false,
            default_value = "",
            comment = ""
    )
    private String hrpName;

    @EntityFieldAnnotation(
            text = "备注",
            length = "200",
            not_null = false,
            default_value = "",
            comment = ""
    )
    private String remark;

    @EntityFieldAnnotation(
            text = "科室仓库Id",
            type = EntityFieldType.LONG,
            length = "",
            not_null = false,
            default_value = "",
            comment = ""
    )
    private String warehouseId;

    @EntityFieldAnnotation(
            text = "科室仓库",
            length = "200",
            not_null = false,
            default_value = "",
            comment = ""
    )
    private String warehouseName;

    @EntityFieldAnnotation(
            text = "允许查看全院数据",
            length = "",
            not_null = true,
            default_value = "0",
            comment = ""
    )
    private Boolean flagAllData;

    @EntityFieldAnnotation(
            text = "限制请领范围",
            length = "",
            not_null = true,
            default_value = "1",
            comment = ""
    )
    private Boolean flagApplyLimit;

//    @EntityFieldAnnotation(
//            text = "不显示仓库区域",
//            length = "",
//            not_null = true,
//            default_value = "0",
//            comment = ""
//    )
//    private boolean flagWarehouse;


    // creator ,在父类中处理


    // gmt_create ,在父类中处理


    // modifier ,在父类中处理


    // gmt_modified ,在父类中处理

    //科室地址
    @EntityFieldAnnotation(
            text = "科室地址",
            length = "200",
            not_null = false,
            default_value = "",
            comment = ""
    )
    private String addressName;

    //科室地址
    @EntityFieldAnnotation(
            text = "是否为服务科室",
            length = "",
            not_null = false,
            default_value = "0",
            comment = "0：否，1:是"
    )
    private String flagServiceDept;

    @EntityFieldAnnotation(
            text = "阳采编码",
            length = "30",
            not_null = false,
            default_value = "",
            comment = "阳采科室代码"
    )
    private String sunCode;

    @EntityFieldAnnotation(
            text = "阳采名称",
            length = "100",
            not_null = false,
            default_value = "",
            comment = "阳采科室名称"
    )
    private String sunName;

    // 所属机构名称
    @TableField(exist = false)
    private String officeName;

    @EntityFieldAnnotation(
            text = "是否禁用科室",
            length = "",
            not_null = false,
            default_value = "0",
            comment = "0：否，1:是"
    )
    private String flagDisabled;

    @EntityFieldAnnotation(
            text = "试剂管理权限",
            length = "",
            not_null = false,
            default_value = "0",
            comment = "0：否，1:是"
    )
    private Boolean flagReagent;

}
